#pragma once
#ifndef CNETSENDER_H
#define CNETSENDER_H
#include "winsock2.h"
#define CONNSIZE 10

class CBaseFilter;
class CNetSender
{
public:
	CNetSender(HRESULT *   phr);

	HRESULT Start();
	HRESULT Stop();

	static DWORD WINAPI InitialSndProc(LPVOID pv);

	HRESULT Send (char* pbBuffer,DWORD dwLength);

private:

	HRESULT Send ();

	HRESULT ArraySend(BYTE* pBuf);

public:
	~CNetSender(void);

private:
	SOCKET m_sktConn;
	sockaddr_in m_service;

	HANDLE m_hThread;

	HANDLE m_hSndThread;
	DataItem m_dataItem;
};

#endif